<!DOCTYPE html>
<html >
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>内边距</title>
    <style>
        .box{
            display: inline-block;
            width: 300px;
            height: 300px;
            border: 10px solid blue;
            background-color: lightblue;
            padding: 20px;
            margin: 20px;
        }
        .box1{
            display: inline-block;
            width: 300px;
            height: 300px;
            border: 10px solid blue;
            background-color: lightblue;
            padding: 20px;
            margin: 20px;
            box-sizing: border-box;
        }
    </style>
</head>
<body>
    <div class="box">
        <span>你好</span>
    </div>
    <div class="box1">
        <span>你好</span>
    </div>
</body>
</html>